package cn.comon;

import cn.entity.Employee;

public class UserSession {
    private static UserSession instance;
    private Employee currentUser;

    private UserSession() {
    }

    public static synchronized UserSession getInstance() {
        if (instance == null) {
            instance = new UserSession();
        }
        return instance;
    }

    public void setCurrentUser(Employee user) {
        this.currentUser = user;
    }

    public Employee getCurrentUser() {
        return currentUser;
    }
}
